<template>
    <div class="photoinfo">
        <h2>我是标题区域</h2>
        <p class="subtitle">
            <span>发表时间：{{new Date()|dateFormat}}</span>
            <span>点击：0次</span>
        </p>
        <hr>
        <div class="thumbs">
            <template>
                <vue-preview :slides="slide1" @close="handleClose"></vue-preview>
            </template>
        </div>

        <div class="content">
            我是内容区域
        </div>
        <cmt></cmt>

    </div>
</template>

<script>
import cmt from "../sub/commit.vue";
export default {
  data() {
    return {
      slide1: [
        {
          src:
            "https://farm6.staticflickr.com/5591/15008867125_68a8ed88cc_b.jpg",
          msrc:
            "https://farm6.staticflickr.com/5591/15008867125_68a8ed88cc_m.jpg",
          alt: "picture1",
          title: "Image Caption 1",
          w: 600,
          h: 400
        },
        {
          src:
            "https://farm4.staticflickr.com/3902/14985871946_86abb8c56f_b.jpg",
          msrc:
            "https://farm4.staticflickr.com/3902/14985871946_86abb8c56f_m.jpg",
          alt: "picture2",
          title: "Image Caption 2",
          w: 1200,
          h: 900
        }
      ]
    };
  },
  methods: {
    handleClose() {
      console.log("close event");
    }
  },
  components: {
    cmt
  }
};
</script>
<style lang="scss" scoped>
.photoinfo {
  padding: 3px;
  h2 {
    text-align: center;
    font-size: 15px;
    color: aqua;
    margin: 15px 0;
  }
  .subtitle {
    display: flex;
    justify-content: space-between;
    font-size: 13px;
  }
  .content {
    font-size: 13px;
    line-height: 30px;
  }
}
</style>

